import request from "@/utils/request";

/* 上传管理 */

// 数据表格 错误码300801
export function list(params) {
  return request({
    url: "/system/management/list",
    method: "get",
    params,
  });
}

// 删除 错误码300802
export function deleteUp(id) {
  return request({
    url: `system/management/${id}`,
    method: "delete",
  });
}

// 新增 错误码300803
export function uploadFile(data) {
  return request({
    url: "/system/management",
    method: "post",
    data,
  });
}

// 根据显示模板获取公文信息 错误码300804
export function getPlatelist(params) {
  return request({
    url: `/system/management/plate/list/${params}`,
    method: "get",
  });
}

// 审核 错误码300805
export function audit(data) {
  return request({
      url: `/system/management/audit`,
      method: 'post',
      data
  })
}

// 驳回 错误码300806
export function reject(data) {
  return request({
      url: `/system/management/reject`,
      method: 'post',
      data
  })
}

// 上传 错误码300807
export function plugset(data) {
  return request({
      url: `/system/management/upload`,
      method: 'post',
      data
  })
}

// 详情 错误码300808
export function detail(id) {
  return request({
      url: `/system/management/${id}`,
      method: 'get',
  })
}
